import serverAuth from "@/app/utils/serverAuth";
import { NextResponse } from "next/server";

export const GET = async ()=>{
    try {
        "use server";
        const {currentUser} = await serverAuth();
        // console.log("currentUser",currentUser)
        return  NextResponse.json({ data: currentUser }, { status: 200 })
    } catch (error) {
        console.log('current',error)
        return NextResponse.json({ message:"Internal server error" }, { status: 400 })
    }

}





